.container1 {
  display: flex;
  flex-direction: column;
  height: 90vh;
  /* 关键：容器占满全屏 */
}

.header {
  padding: 20rpx;
  border-bottom: 1px solid #eee;
  display: flex;
  align-items: center;
}

.avatar {
  width: 60rpx;
  height: 60rpx;
  border-radius: 50%;
  margin-right: 15rpx;
}

.title {
  font-size: 32rpx;
  font-weight: bold;
}

/* 聊天区域关键样式 */
.chat-container {
  flex: 1;
  /* 关键：占满剩余空间 */
  padding: 20rpx;
  box-sizing: border-box;
  overflow: hidden;
  
}

.chat-list {
  min-height: 100%;
  /* 确保容器高度足够 */
}

.chat-item {
  margin-bottom: 25rpx;
  display: flex;
}

/* 系统消息居左 */
.system {
  justify-content: flex-start;
}

.system .bubble {
  background: #e5e5ea;
  padding: 15rpx 20rpx;
  border-radius: 18rpx 18rpx 18rpx 0;
  max-width: 100%;
}

/* 用户消息居右 */
.user {
  justify-content: flex-end;
}

.user .bubble {
  background: #07c160;
  color: white;
  padding: 15rpx 20rpx;
  border-radius: 18rpx 18rpx 0 18rpx;
  max-width: 70%;
}

.options {
  margin-top: 10rpx;
  display: flex;
  flex-wrap: wrap;
  gap: 10rpx;
}

.options button {
  padding: 8rpx 15rpx;
  font-size: 24rpx;
  border-radius: 15rpx;
  background: white;
  border: 1px solid #eee;
}

.input-bar {
  position: fixed;
  bottom: 0rpx;
  padding: 15rpx;
  display: flex;
  flex-direction: column;
  border-top: 1px solid #eee;
  background: white;
  width: 100vw;
}

.input-bar input {
  flex: 1;
  height: 70rpx;
  background: #f5f5f5;
  border-radius: 30rpx;
  padding: 0 20rpx;
  margin-right: 15rpx;
}

.input-bar button {
  width: 120rpx;
  height: 60rpx;
  line-height: 60rpx;
  background: #07c160;
  color: white;
  border-radius: 30rpx;
  font-size: 28rpx;
  padding: 0;
}



/* 光标动画 */
.cursor {
  animation: blink 1s infinite;
}

@keyframes blink {
  0% {
    opacity: 1;
  }

  50% {
    opacity: 0;
  }

  100% {
    opacity: 1;
  }
}

/* 加载动画 */
.dot-flashing {
  animation: dotFlashing 3s linear;
}

@keyframes dotFlashing {
  0% {
    background-color: #888;
  }

  50% {
    background-color: rgba(136, 136, 136, 0.2);
  }

  100% {
    background-color: #888;
  }
}

.textarea {
  background-color: #eee;
  height: 95rpx;
  line-height: 25rpx;
  padding: 15rpx;
}